#include "LutColorRVB8.h"

using namespace boost::gil;

LutColorRVB8::LutColorRVB8()
{
    m_color=rgb8_pixel_t(0);
}
LutColorRVB8::~LutColorRVB8()
{}

void
LutColorRVB8::setValues(uint32_t C1, uint32_t C2, uint32_t C3)
{
    //TODO test bound before assign value
    m_color[0]=C1;
    m_color[1]=C2;
    m_color[2]=C3;
}

uint32_t
LutColorRVB8::getC1i() const
{
    return static_cast<uint32_t>(m_color[0]);
}
uint32_t
LutColorRVB8::getC2i() const
{
    return static_cast<uint32_t>(m_color[1]);
}
uint32_t
LutColorRVB8::getC3i() const
{
    return static_cast<uint32_t>(m_color[2]);
}
void
LutColorRVB8::setValues(float C1, float C2, float C3)
{
    //TODO test bound before assign value and scale ?
    m_color[0]=C1;
    m_color[1]=C2;
    m_color[2]=C3;
}
float
LutColorRVB8::getC1f() const
{
    return static_cast<float>(m_color[0]);
}
float
LutColorRVB8::getC2f() const
{
    return static_cast<float>(m_color[1]);
}
float
LutColorRVB8::getC3f() const
{
    return static_cast<float>(m_color[2]);
}
